const fs=require('fs');
let data='';
let readerStream=fs.createReadStream('test.txt');
readerStream.setEncoding('utf8');
readerStream.on('data',(chunk)=>{data+=chunk;});
readerStream.on('end',()=>console.log(data));
readerStream.on('error',(err)=>console.log(err.stack));
console.log('finish');
